package demo2;

public class Mylist {
    public static void main(String[]args){
        List list=new List();
        list.add(1);
        list.add(2);
        list.add(3);
        list.add(4);
        list.add(5);
        System.out.println(list.size());
        System.out.println("========");
        System.out.println(list.get(4));
        System.out.println("=======");
        list.display();
        System.out.println("===========");
       int b= list.find(3);
       System.out.println("找到了下标为："+b);
        boolean a=list.contain(2);
        System.out.println(a);
        list.add(6);
        System.out.println(list.size());
        System.out.println("========");
        list.display();
        System.out.println("===========");
        list.add(9,3);
        System.out.println(list.size());
        System.out.println("========");
        list.display();
        System.out.println("===========");
        list.remove(2);

        System.out.println(list.size());
        System.out.println("========");
        list.display();
        System.out.println("===========");
        list.set(4,10);
        list.display();
        System.out.println("======");
        list.clear();
        list.display();
    }
}
